package study.java.jdk.jdk8._1_stream.terminal.short_circuiting;

import lombok.extern.slf4j.Slf4j;
import org.junit.Test;

import java.util.Arrays;
import java.util.List;

/**
 * 列表中没有一个元素比配我们的条件
 */
@Slf4j
public class noneMatch_01_Test {

    private List<String> src = Arrays.asList("apple", "banana", "orange");

    /**
     * @param predicate Predicate
     */
    @Test
    public void test() {
        boolean dest = src.stream()
                .noneMatch(e -> "apple9".equals(e));
        log.info("{}", dest);
    }
}
